//
//  CategoryModel.m
//  meituan
//
//  Created by huiwenjiaoyu on 15/12/16.
//  Copyright © 2015年 Rick. All rights reserved.
//

#import "CategoryModel.h"

@implementation CategoryModel

+ (NSArray *)category
{
    NSMutableArray *arryM = [NSMutableArray array];
    NSData *data = [NSData dataWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@"category.json" ofType:nil]];
    NSArray *array = [[NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingMutableContainers error:nil][@"data"] objectForKey:@"homepage"];
    for (NSDictionary *dic in array) {
        
        CategoryModel *category = [[CategoryModel alloc] initContentWithDic:dic];
        [arryM addObject:category];
    }
    return arryM;
}

@end
